<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title> 用户详情</title>
    <link href="/webjars/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet">
    <script src="webjars/jquery/3.0.0/jquery.min.js"></script>
    <script src="webjars/bootstrap/4.3.1/js/bootstrap.min.js"></script>
</head>
<body>

<div th:if="${userPower} eq 'ADMIN'">
    <ul class="nav nav-tabs">
        <li class="nav-item">
            <a class="nav-link active" href="#">个人首页</a>
        </li>
        <li class="nav-item">
            <a class="nav-link" href="/rankinglist.html">排行榜</a>
        </li>
        <li class="nav-item">
            <a class="nav-link" href="/admin/menusmanage.html">菜品管理</a>
        </li>
        <li class="nav-item">
        <a class="nav-link" href="/background.html">订单管理</a>
    </li>
    </ul>
</div>

<div class="container p-5 w-50">
<div class="card">


    <div class="card-header">
        welcome 用户名：
        <div th:text="${userName}" class="font-weight-bold "></div>
    </div>
    <div class="card-body">
        your power is :
        <div th:text="${userPower}" class="font-weight-bold font-italic "></div>
        <div class="row">
            <div class="col-md-6">
                <a th:href="@{'/orderfood.do?uid='+${userId}}" class="font-weight-bold">
                    去下单
                </a>
            </div>
            <div class="col-md-6" th:if="${userPower} eq 'ADMIN' ">
                <a href="/background.html" class="font-weight-bold">管理订单</a>
                <a href="/rankinglist.html" class="font-weight-bold">查看销售榜</a>
                <a href="/admin/menusmanage.html" class="font-weight-bold">管理菜品</a>
            </div>
        </div>
    </div>

    <div class="card-footer">
        欢迎使用点餐系统105
    </div>
</div>
</div>

</body>

</html>